package cn.edu.sasu.domain.dto;

import lombok.Data;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;

@Data
public class UpdatePasswordDTO {
    @NotNull(message = "用户ID不能为空")
    private Integer userId;
    private String oldPassword;
    @Pattern(regexp = "^[a-zA-Z]\\w{5,17}$",message = "以字母开头，长度在6~18之间，只能包含字母、数字和下划线")
    private String newPassword;

}
